package com.lzj.entity;

import java.util.Date;

/**
 * <p>
 *
 * </p>
 *
 * @autor:lzj
 * @date:2021/12/6
 */
public class Order {
    private int id;//订单号
    private Date time;//订单时间
    private boolean state;//订单状态（已支付/未支付）
    private int userId;//所属用户id

    public Order() {
    }

    public Order(Date time, boolean state, int userId) {
        this.time = time;
        this.state = state;
        this.userId = userId;
    }

    public Order(int id, Date time, boolean state, int userId) {
        this.id = id;
        this.time = time;
        this.state = state;
        this.userId = userId;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public Date getTime() {
        return time;
    }

    public void setTime(Date time) {
        this.time = time;
    }

    public boolean isState() {
        return state;
    }

    public void setState(boolean state) {
        this.state = state;
    }

    public int getUserId() {
        return userId;
    }

    public void setUserId(int userId) {
        this.userId = userId;
    }

    @Override
    public String toString() {
        return "Order{" +
                "id=" + id +
                ", time=" + time +
                ", state=" + state +
                ", userId=" + userId +
                '}';
    }
}
